package com.meta.act.app.tenant.common;

public enum FileTypeEnum {

	CREDIT_FILE(1, "营业执照"),
    TAX_FILE(2, "一般纳税人证明")
    ;
    private Integer code;

    private String desc;

    private FileTypeEnum(Integer code, String desc) {
        this.code = code;
        this.desc = desc;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

	public static FileTypeEnum getByCode(Integer code) {
		for (FileTypeEnum fileTypeEnum : values()) {
			if (fileTypeEnum.getCode().equals(code)) {
				//获取指定的枚举
				return fileTypeEnum;
			}
		}
		return null;
	}
}
